The present invention relates to desktop publishing (DTP) and line leading.
DTP documents typically include multiple lines of glyphs, which usually represent characters but can also represent symbols and blank spaces. In a document, the lines of glyphs are arranged vertically, horizontally, or in some combination thereof. This arrangement can be applied to the entire document or any portion of the document.
As characters, symbol, or blank spaces are added to the document and a current line of glyphs is filled, a new line is added adjacent and parallel to the line last filled. The term line procession refers to the described manner of adding lines. A direction of the line procession is the direction in which the lines are added. For example, in a typical page of a DTP document, lines are added from the top of the page to the bottom of the page. Accordingly, the line procession direction is from top to bottom.
Glyphs are usually contained in a virtual body sometimes referred to as an embox. An embox is an outer frame around a glyph and, furthermore, has dimensions and size. The dimensions and size of the embox are determined, respectively, by the shape of the glyph and the type point of a character represented by the glyph. Generally, an embox's dimensions vary from glyph group to glyph group. Specifically, for a group of related glyphs, there is typically an embox of fixed dimensions that can frame every glyph in the group. A related group of glyphs include but is not limited to those representing characters belonging to the same font. In Chinese-Japanese-Korean (“CJK”) DTP systems, the embox's dimensions match the standard escapement of mono-spaced full-width CJK ideographic characters, and thus is called a “ideographic embox”. Generally, an embox's size is determined by the type size of the character represented by the glyph framed. For example, an embox framing a glyph representing a character of type size ten is smaller than one framing the same glyph representing the character of type size twelve.
Where a glyph is placed in an ideographic embox (or analogously where an embox for given a glyph is positioned) depends on the convention of the DTP system. In Roman DTP systems, the main portion of the glyph rests on a baseline. Any ascending or descending portions extend to respective ascender or descender lines. The zero point (or origin) from which a glyph is drawn is conventionally defined to be at the left edge of the base line. In Roman convention, this zero point determines the position of a glyph in an embox. FIG. 5A shows an example of an embox 500 framing a glyph 502 that represents the character “d”. The main portion of the glyph rests on the baseline 504 and the ascending stem extends to the ascending line 506. The zero point 508 is located as shown. FIG. 5B shows another example of the embox 500 framing a glyph 510 that represents the character “y”. The main portion of the glyph rests on baseline 504 and the descending stem extends to descending line 512. As evident from FIG. 5C, the glyphs 502 and 510 can be lined up in a row by arranging their emboxes so that their base lines form are colinear.
In CJK DTP systems, although there is usually a baseline and a zero point in an embox, the glyphs representing the ideographical characters are positioned at an arbitrary point relative to the zero point. To perform correct Japanese typography with digital fonts defined according to the described Roman convention, it is necessary to calculate where the ideographic embox rests relative to the zero point (i.e., the Roman baseline). For example, some fonts are designed so their ideographic characters rest 88% above the Roman baseline and 12% below. In such a font, the ideographic embox is thus defined as having 12% of its height below the baseline.
FIG. 6A shows an example of an embox 600 framing a glyph 602 representing an ideographic character. The position of the glyph 602 with respect to the embox 600 is determined by the specified percent above the baseline 604, which unlike those in the Roman DTP systems, is not necessarily universally located at the same place in the embox. That is, in CJK DTP systems, the location of the baseline 604 is arbitrary and can vary. In this case, approximately 88 percent of the glyph 602 is above the baseline 604. FIG. 6B shows an example of the embox 600 framing another glyph 606, which is positioned using the 88 percent criteria. As evident from FIG. 6C, the glyphs 602 and 606 do not line up in a row by arranging their emboxes so that their baselines form a straight line.
How lines of glyphs are defined in a DTP system also depends on the convention of the DTP system. A line of glyphs usually includes a top line and a bottom line. Roman DTP systems set the bottom line of a current line of glyphs to coincide with the baseline of the emboxes in the current line of glyphs. The top line of the current line of glyphs is set to coincide with the baseline of emboxes in the previous line of glyphs. This convention ensures that the glyphs in a line of glyphs are line up properly.
FIG. 7 shows an example of the Roman line definition. As shown, the top line 702 of a line of glyphs 704 is defined to coincide with the baseline 706 of the emboxes in the previous line of glyphs 708. The bottom line 710 of the line of glyphs 704 is defined to coincide with the baseline 712 of the emboxes in the line of glyphs 704.
CJK DTP systems cannot use the technique described in the preceding paragraphs to ensure proper glyph alignment because, as discussed, CJK glyphs are positioned at an arbitrary point relative to the zero point. CJK DTP systems set the top line of a current line of glyphs to coincide with the top edge of a largest embox in the current line of glyphs. The bottom line of the current line of glyph is set to be the bottom of the largest embox. Aligning CJK and Roman glyphs is further described in PCT Application No. US0104499, entitled “Method for Determining Line Leading”, filed on Feb. 12, 2001, which is hereby incorporated by reference in its entirety. Aligning CJK and Roman glyphs is also further described in U.S. application Ser. No. 09/782,597, entitled “Method for Calculating CJK Emboxes in Fonts”, filed on Feb. 12, 2001, which is hereby incorporated by reference in its entirety.
FIG. 8 shows an example of the CJK line definition. As shown, the top line 802 of a line of glyphs 804 is defined to coincide with the top edge 806 of the largest embox 808 in the line of glyphs 804. The bottom line 810 of the line of glyphs 804 is defined to coincide with the bottom edge 812 of the largest embox 808. Additionally, there may be spacing, referred to as Aki, between adjacent lines. To ensure proper alignment, CJK DTP systems typically position a glyph at the center of the embox and align emboxes in a line of glyphs by their embox centers.
Line leading refers to the distance between adjacent lines of glyphs. Most DTP systems measure line leading the same way for both Roman and CJK conventions. Specifically, the line leading is measure from the baseline of a current line of glyphs to the baseline of an immediately preceding line of glyphs. FIG. 9 shows an example of the Roman line leading model. Unfortunately, this line leading model can result in unaesthetic line placement when applied to the CJK DTP systems. As shown, line leading, depicted as a ray 902, is measured from the baseline 904 in the current line of glyphs 906 to the baseline 908 in the previous line of glyphs 910. One problem caused by using the Roman line leading model in CJK DTP systems is that, as discussed, the CJK line definition is not the same as the Roman line definition. Forcing the Roman line leading model onto CJK DTP systems usually results in irregular distances between lines of glyphs mostly because, as discussed, these systems define lines differently and the CJK system positions glyphs at an arbitrary point relative to the zero point.